<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <title>异常登录页面</title>
</head>
<body>
    <!--意思一下不要太在乎页面效果-->
    <b style="font-size: 50px" th:if="${noAuthority!=null}" th:text="${noAuthority}"></b>
    <b style="font-size: 50px" id="noLogin" th:if="${noLogin!=null}" th:text="${noLogin}"></b>
    <b th:if="${noLogin!=null}" style="color: red">
        <b id="time">3</b>
        秒后跳转登录页面（不要太在意页面效果 嘻嘻）
    </b>
    <script th:src="@{/js/jquery.js}"></script>
    <script th:src="@{/js/global.js}"></script>
<script type="text/javascript">
    window.onload = function (){
        if ($('#noLogin')!=null){
            var interval = window.setInterval(function (){

                var text = $('#time').text();
                var number = parseInt(text);
                if (number===0){
                    window.location.href = CONTEXT_PATH+"/user/login.html"
                    clearInterval(interval)
                    return
                }
                --number;
                $('#time').text(number);
            },1000)
        }
    }
</script>
</body>
</html>